// Navbar
// Side navbar and top navbar

.navbar-side {
  position: absolute;
  width: $navbar-side-width;
  background-color: transparent;
  transition: all .4s;

  li {
    border-left: 4px solid transparent;

    &:hover {
      border-color: $nav-active-bg;
    }

    + li {
      margin-top: 0;
    }

    > a {
      .fa, .glyphicon {
        margin-right: 6px;
      }

      .arrow {
        line-height: 20px;
        transition: transform .3s ease;
      }
    }

    &.active {
      border-left: 4px solid $success-color;
      background: $nav-active-bg;
      transition: all .4s;

      > a .arrow {
        transform: rotate(-90deg);
      }
    }
  }
}

.nav-header {
  padding: 33px 25px 25px;
  background: url($nav-header-bg-image) no-repeat;

  .header-image {
    display: block;
    width: $nav-header-image-size;
    height: $nav-header-image-size;
    margin-bottom: 5px;
    overflow: hidden;
    font-size: 0;

    img {
      width: 100%;
    }
  }

  a {
    color: $nav-header-link-color;
    text-decoration: none;
  }

  .text-muted {
    color: $nav-header-light-color;
  }
}

.nav-cell {
  padding-bottom: 10px;
  border-bottom: 1px solid $nav-active-bg;

  + .nav-cell {
    border-top: 1px solid lighten($nav-active-bg, 5%);
    border-bottom: 0;
  }
}

.nav-cell-header {
  padding: 10px 20px;
  font-size: 16px;
  color: $nav-cell-color;
  font-weight: 600;
}

.nav > li > a {
  font-weight: 600;
  color: $nav-color;
  padding: 14px 20px;

  &:focus,
  &:hover {
    color: #fff;
    background-color: $nav-active-bg;
  }
}

.nav > .active > a {
  color: #fff;
  background-color: $nav-active-bg;
}

.nav-second-level li {
  border-left: 0;

  > a {
    padding: 7px 10px;
    padding-left: 52px;
  }

  &.active {
    border-left: 0;
  }
}

.navbar-top {
  height: $navbar-top-height;
  margin-bottom: 0;
  background: $navbar-top-bg;

  .navbar-brand {
    float: none;
    position: absolute;
    width: $navbar-top-brand-width;
    height: $navbar-top-height;
    left: 50%;
    margin-left: - $navbar-top-brand-width / 2;
    padding: 15px;
    line-height: $navbar-top-height - 15 * 2;
    text-align: center;

    > img {
      height: 30px;
      width: 30px;
      margin: 0 auto;
    }
  }
}

.navbar-top-nav {
  > li {

    > a {
      padding: 20px 15px;
    }

    &:last-child {
      margin-right: 40px;
    }
  }

  .badge-pending .label {
    position: absolute;
    right: 4px;
    top: 14px;
    padding: 2px 4px 3px;
    box-shadow: -1px 1px 0 $navbar-top-bg;
  }
}

.submenu-header {
  padding: 30px 20px 0;
  border-bottom: 1px solid $navbar-top-border;
  background: $navbar-top-bg;
}

.submenu {
  > li {

    + li {
      margin-left: 0;
    }

    > a {
      padding: 10px 30px 5px;
      border-radius: 0;
      border-bottom: 5px solid transparent;
      color: $gray-light;

      &:hover, &:focus {
        color: $gray;
        background: $navbar-top-bg;
        border-bottom-color: $success-color;
      }
    }
  }

  li.active > a,
  li.active > a:focus,
  li.active > a:hover {
    color: $gray;
    background: $navbar-top-bg;
    border-bottom-color: $success-color;
  }
}
